﻿/*
Post-Deployment Script Template							
--------------------------------------------------------------------------------------
 This file contains SQL statements that will be appended to the build script.		
 Use SQLCMD syntax to include a file in the post-deployment script.			
 Example:      :r .\myfile.sql								
 Use SQLCMD syntax to reference a variable in the post-deployment script.		
 Example:      :setvar TableName MyTable							
			   SELECT * FROM [$(TableName)]					
--------------------------------------------------------------------------------------
*/
GO

/*  Make the sa account the owner of the centraldba db      */
EXEC sp_changedbowner 'sa'

/*  Set database settings                                   */
EXEC	[dbo].[spMaint_InitDatabase]

/*  Configure msdb with indexes, roles, and permissions     */
EXEC	[dbo].[spMaint_InitMsdb]

/*  Configure default alerts and operators                  */
EXEC	[dbo].[spMaint_InitAlertsOperators]
GO